package com.zhentao.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.zhentao.activity.domain.AdActivity;
import com.zhentao.common.dtos.ResponseResult;
import com.zhentao.service.AdActivityService;
import com.zhentao.mapper.AdActivityMapper;
import org.springframework.stereotype.Service;

import java.util.List;

/**
* @author 86188
* @description 针对表【ad_activity】的数据库操作Service实现
* @createDate 2024-08-31 10:09:52
*/
@Service
public class AdActivityServiceImpl extends ServiceImpl<AdActivityMapper, AdActivity>
    implements AdActivityService{

    @Override
    public ResponseResult indexHomeList() {
        LambdaQueryWrapper<AdActivity> wrapper=new LambdaQueryWrapper<>();
        wrapper.orderByDesc( AdActivity::getCreateTime);
        List<AdActivity> list = list(wrapper);
        return ResponseResult.okResult(list);
    }
}




